package com.vcms.view.simulation.uifactory;

public abstract class VMCSUIFactory {

	private static VMCSUIFactory singleton;
	public static final int AWTFactory = 0;
	
	public static synchronized VMCSUIFactory getInstance() {
		
		//default set to AWTFactory
		//in future can set to other UI family to create UI components
		return getInstance(AWTFactory);
	}
	
	private static synchronized VMCSUIFactory getInstance(int type) {
		if (type == AWTFactory) {
			singleton = new AWTFactory();
		} else {
			throw new UnsupportedOperationException("Unsupport paramater for factory");
		}
		return singleton;
	}
	
	public abstract VMCSAbstractButton createButton();
	public abstract VMCSAbstractLabel createLabel();
	public abstract VMCSAbstractPanel createPanel();
	public abstract VMCSAbstractTextField createTextField();
	
}
